package com.semanticbits.codejam.model

/**
 * Created by IntelliJ IDEA.
 * User: carlos.perez
 * Date: 1/16/11
 * Time: 10:37 AM
 * To change this template use File | Settings | File Templates.
 */

EmailTemplate email = new EmailTemplate()
Contest contest = new Contest();
contest.title = "my title"
String text = "This is a title \${contest.title} ";

print email.applyTemplate( text, contest )

app.Application.SHARED_DIR="c:/java/aribaweb-5.0GA/codejammer/CodeJamManager/resource/webserver/mail"

email.saveMessage(contest, email.applyTemplate( text, contest), "ann" );
email.saveMessage(contest, email.applyTemplate( text, contest), "win" );

contest.send();